//
// CPSForceIntensity.java
// Copyright (C) 2010  "Naush" <naush _ hotmail _ fr>
//
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU Affero General Public License as
// published by the Free Software Foundation, either version 3 of the
// License, or (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
// GNU Affero General Public License for more details.
//
// You should have received a copy of the GNU Affero General Public License
// along with this program.  If not, see <http://www.gnu.org/licenses/>./* ----------------------------------------------------------------------------







package org.ryzom.nel.threed;

import org.ryzom.nel.misc.IStream;

public class CPSForceIntensity {
  private long swigCPtr;
  protected boolean swigCMemOwn;

  public CPSForceIntensity(long cPtr, boolean cMemoryOwn) {
    swigCMemOwn = cMemoryOwn;
    swigCPtr = cPtr;
  }

  public static long getCPtr(CPSForceIntensity obj) {
    return (obj == null) ? 0 : obj.swigCPtr;
  }

  protected void finalize() {
    delete();
  }

  public synchronized void delete() {
    if (swigCPtr != 0) {
      if (swigCMemOwn) {
        swigCMemOwn = false;
        nel3dJNI.delete_CPSForceIntensity(swigCPtr);
      }
      swigCPtr = 0;
    }
  }

  public float getIntensity() {
    return nel3dJNI.CPSForceIntensity_getIntensity(swigCPtr, this);
  }

  public void setIntensity(float value) {
    nel3dJNI.CPSForceIntensity_setIntensity(swigCPtr, this, value);
  }

  public void setIntensityScheme(SWIGTYPE_p_NL3D__CPSAttribMakerT_float_t scheme) {
    nel3dJNI.CPSForceIntensity_setIntensityScheme(swigCPtr, this, SWIGTYPE_p_NL3D__CPSAttribMakerT_float_t.getCPtr(scheme));
  }

  public void setupFunctor(long indexInLocated) {
    nel3dJNI.CPSForceIntensity_setupFunctor(swigCPtr, this, indexInLocated);
  }

  public SWIGTYPE_p_NL3D__CPSAttribMakerT_float_t getIntensityScheme() {
    long cPtr = nel3dJNI.CPSForceIntensity_getIntensityScheme__SWIG_0(swigCPtr, this);
    return (cPtr == 0) ? null : new SWIGTYPE_p_NL3D__CPSAttribMakerT_float_t(cPtr, false);
  }

  public void serialForceIntensity(IStream f) {
    nel3dJNI.CPSForceIntensity_serialForceIntensity(swigCPtr, this, IStream.getCPtr(f), f);
  }

}
